<!DOCTYPE html>
<html lang="en" xmlns:th="http://www.w3.org/1999/xhtml">
<head>
    <th:block th:include="include :: header('首页')" />
</head>
<body class="layui-layout-body">
<div class="layui-layout layui-layout-admin">
    <div class="layui-header">
        <div class="layui-logo">酒店管理系统</div>
        <ul class="layui-nav layui-layout-right">
            <li class="layui-nav-item">
                <a href="javascript:;" >
                    [[${session.admin.username}]]
                </a>
<!--                <dl class="layui-nav-child">-->
<!--                    <dd><a href="">基本资料</a></dd>-->
<!--                    <dd><a href="">安全设置</a></dd>-->
<!--                </dl>-->
            </li>
            <li class="layui-nav-item"><a href="/admin/toLoginOut">退了</a></li>
        </ul>
    </div>

    <div class="layui-side layui-bg-black" >
        <div class="layui-side-scroll" th:if="${session.admin}">
            <!-- 左侧导航区域（可配合layui已有的垂直导航） -->
            <ul class="layui-nav layui-nav-tree"  lay-filter="test">
                <li class="layui-nav-item layui-nav-itemed">
                    <a class="" href="javascript:;">用户管理</a>
                    <dl class="layui-nav-child">
                        <dd><a href="/admin/admin">用户列表</a></dd>
                    </dl>
                </li>
                <li class="layui-nav-item">
                    <a href="javascript:;">酒店管理</a>
                    <dl class="layui-nav-child">
                        <dd><a href="/admin/hotel">酒店列表</a></dd>
                        <dd><a href="/admin/room">房间列表</a></dd>
                        <dd><a href="/admin/roomType/">房间类型列表</a></dd>
                    </dl>
                </li>
                <li class="layui-nav-item"><a href="javascript:;">客户管理</a>
                    <dl class="layui-nav-child">
                        <dd><a href="/admin/useer/">客户列表</a></dd>
                        <dd><a href="/admin/address/">客户地址列表</a></dd>
                    </dl></li>
                <li class="layui-nav-item">
                    <a href="javascript:;">订单管理</a>
                    <dl class="layui-nav-child">
                        <dd><a href="/admin/student">预定管理</a></dd>
                        <dd><a href="/admin/classes">入住管理</a></dd>
                        <dd><a href="/admin/teacher">退房管理</a></dd>
                    </dl>
                </li>
            </ul>
        </div>
    </div>

    <div class="layui-body">
        <!-- 内容主体区域 -->
        <iframe id="iframeMain" src="/admin/index/toMain" style="width: 100%;" height="100%"></iframe>
    </div>

<!--    <div class="layui-footer">-->
<!--        &lt;!&ndash; 底部固定区域 &ndash;&gt;-->
<!--        © layui.com - 底部固定区域-->
<!--    </div>-->
</div>
<th:block th:include="include :: footer" />
<script>
    $(document).ready(function(){
        $("dd>a").click(function (e) {
            e.preventDefault();
            $("#iframeMain").attr("src",$(this).attr("href"));
        });
    });
</script>
<script>
    //JavaScript代码区域
    layui.use('element', function(){
        var element = layui.element;

    });
    </script>
</body>
</html>
